package org.tedu.weibo.pojo.dto;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.*;
import java.util.Date;

@Data
public class UserLoginDTO {

    //@NotNull(message="用户名不能为NULL")
    //@NotEmpty(message="用户名不能为空")
    @NotBlank(message="用户名不能为空")
    //@Size(min = 6, max = 20, message="用户名必须在6-20个字符之内")
    @Pattern(regexp = "^[\\u4e00-\\u9fa5]{1,7}|[A-Za-z0-9]{1,14}$", message="用户名要1-7个中文或者1-14个字符")
    @ApiModelProperty(value = "用户名", required = true, example = "陆羽")
    private String username;
    @ApiModelProperty(value = "密码", required = true, example = "123456")
    private String password;
}
